package com.rule.easyrule.mapper;

import com.rule.easyrule.entity.BizRuleComposePo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;


@Mapper
public interface BizRuleComposeMapper{

  /**
   * 通过规则查
   *
   * @param ruleId 规则ID
   * @return 结果
   */
  List<BizRuleComposePo> selectByRule( @Param("ruleId") Long ruleId);

  /**
   *批量插入组合规则[{}],插入结果[{}]
   * @param list
   * @return
   */
  int batchInsert(List<BizRuleComposePo> list);

  /**
   *更新
   * @param bizRuleComposePo
   * @return
   */
  int update(BizRuleComposePo bizRuleComposePo);

  /**
   *
   * @param id
   * @return
   */
  BizRuleComposePo selectById(@Param("id") Long id);


}
